# Reference: <https://postmarketos.org/devicepkg>
# Maintainer: hexaheximal <hexaheximal@proton.me>
pkgname=device-odroid-c4
pkgdesc="ODROID C4"
pkgver=1
pkgrel=1
url="https://postmarketos.org"
license="MIT"
arch="aarch64"
options="!check !archcheck"
depends="postmarketos-base u-boot-amlogic-odroid-c4 soc-amlogic-s905 linux-postmarketos-amlogic"
makedepends="devicepkg-dev"
subpackages="$pkgname-nonfree-firmware:nonfree_firmware"
source="deviceinfo modules-initfs"

build() {
	devicepkg_build $startdir $pkgname
}

package() {
	devicepkg_package $startdir $pkgname
}

nonfree_firmware() {
	pkgdesc="ODROID C4 firmware"
	depends="linux-firmware-meson"
	mkdir "$subpkgdir"
}

sha512sums="
1468be3d14b10ceed3921fb4f76fa147ea83b31d0c70d25537deae8717503adf2ceb9c792ec1417fa3d4712d3855c191934699c3e7a736f1fe09eb6de58563e5  deviceinfo
b9f3e1902c17909de928c99868265a257ba5873f6ea6aa1097ad10721f59d68342d50ee51992472ecd23722f7664a13dd15f4e26071a40595c7c3e5161e533d7  modules-initfs
"
